﻿using Domain.Views;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
using System;
using System.Collections.Generic;
using System.Text;

namespace EFcore.Mapping
{
    public sealed class ProductViewMap
    {
        public static void ProductView(EntityTypeBuilder<ProductView> builder)
        {
            //设置表名，主键
            builder.ForMySqlToTable("ProductView");
            builder.HasKey(c => c.Product_Id);
            
        }
    }
}
